package com.realestate.model;

import java.io.Serializable;
import javax.persistence.*;

import java.util.Date;
import java.util.Set;


/**
 * The persistent class for the brtb_district database table.
 * 
 */
@Entity
@Table(name="brtb_district")
public class BrtbDistrict implements Serializable {
	private static final long serialVersionUID = 1L;

	private Long id;

	private String districtCode;

	private String districtName;

	private Date makeDate;

	private String recordStatus;

	private Set<BrtbProduct> brtbProducts;
	
	private BrtbProvince brtbProvince;

    public BrtbDistrict() {
    }

    @Id
	public Long getId() {
		return this.id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	@Column(name="district_code")
	public String getDistrictCode() {
		return this.districtCode;
	}

	public void setDistrictCode(String districtCode) {
		this.districtCode = districtCode;
	}

	@Column(name="district_name")
	public String getDistrictName() {
		return this.districtName;
	}

	public void setDistrictName(String districtName) {
		this.districtName = districtName;
	}

	@Column(name="make_date")
	public Date getMakeDate() {
		return this.makeDate;
	}

	public void setMakeDate(Date makeDate) {
		this.makeDate = makeDate;
	}

	@Column(name="record_status")
	public String getRecordStatus() {
		return this.recordStatus;
	}

	public void setRecordStatus(String recordStatus) {
		this.recordStatus = recordStatus;
	}

	@OneToMany(mappedBy="brtbDistrict")
	public Set<BrtbProduct> getBrtbProducts() {
		return this.brtbProducts;
	}

	public void setBrtbProducts(Set<BrtbProduct> brtbProducts) {
		this.brtbProducts = brtbProducts;
	}
	
	@ManyToOne
	@JoinColumn(name="province_id")
	public BrtbProvince getBrtbProvince() {
		return this.brtbProvince;
	}

	public void setBrtbProvince(BrtbProvince brtbProvince) {
		this.brtbProvince = brtbProvince;
	}
	
}